package es.cea.tags;

import java.io.IOException;

import javax.servlet.jsp.JspException;
import javax.servlet.jsp.JspWriter;
import javax.servlet.jsp.tagext.TagSupport;

public class FormularioRegistroTag extends TagSupport{
	
	private String accion;
	private String metodo;
	
	@Override
	public int doStartTag() throws JspException {
		
		pageContext.getSession();
		
		JspWriter out = pageContext.getOut();
		try {
			out.println("<form action=' " + accion +" ' method=' " + metodo + " '>"+
			"Nombre: <input type='text' name='nombreUsuario' value =''> <br></br>" +
			"Clave de usuario: <input type='text' name='claveUsuario' value =''> <br></br>" +
			"<input type='submit' value='Entrar'> <br></br>" +
			"</form>");
	
		} catch (IOException e) {
			throw new JspException(e);
		}
		return SKIP_BODY;
	}
	
	public String getAccion() {
		return accion;
	}
	public void setAccion(String accion) {
		this.accion = accion;
	}
	public String getMetodo() {
		return metodo;
	}
	public void setMetodo(String metodo) {
		this.metodo = metodo;
	}
	
	

}
